<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>image</title>
    <style>
        .img-full{
            width: 100%;
        }
    </style>
</head>
<body>
<div class="container-fluid">
    <div class="row text-center">
        <div class="col-md-12 text-center">
            <h1>Requirejs 组件库</h1>
            <p>图片案例 </p>
            <p><a href="index.html" class="btn btn-success">返回上一页</a></p>
        </div>
    </div>
    <div class="row row-span-1">
        <div class="col-md-6">
            <div class="alert alert-primary" role="alert">
                fancybox
            </div>
            <div class="row">
                <div class="col-md-2">
                    <a data-fancybox="gallery" href="static/images/demo.png"><img src="static/images/demo.png" alt="" class="img-full" ></a>
                </div>
                <div class="col-md-2">
                    <a data-fancybox="gallery" href="static/images/demo.png"><img src="static/images/demo.png" alt="" class="img-full" ></a>
                </div>
                <div class="col-md-2">
                    <a data-fancybox="gallery" href="static/images/demo.png"><img src="static/images/demo.png" alt="" class="img-full" ></a>
                </div>
            </div>
        </div>
        <div class="col-md-6">
            <div class="alert alert-primary" role="alert">
                lightgallery
            </div>
            <div class="row" id="lightgallery">
                <div class="col-md-3">
                    <a href="static/images/demo.png"><img src="static/images/demo.png" alt="" class="img-full"></a>
                </div>
                <div class="col-md-3">
                    <a data-fancybox="gallery" href="static/images/demo.png"><img src="static/images/demo.png" alt="" class="img-full" ></a>
                </div>
                <div class="col-md-3">
                    <a data-fancybox="gallery" href="static/images/demo.png"><img src="static/images/demo.png" alt="" class="img-full" ></a>
                </div>
            </div>
        </div>
        <div class="col-md-6">
            <div class="alert alert-primary" role="alert">
                <strong>viewer</strong>
            </div>
            <div class="col-md-4">
                <img src="static/images/demo1.jpg" alt="" style="width: 100%">
            </div>
        </div>
    </div>
</div>

<script src="js/require.js"></script>
<script src="js/main.js"></script>
<script>
    // 鼠标特效 + bootstrap
    requirejs(["cursor",'bootstrap4']);

    //fancybox
    requirejs(["fancybox",'bigimage'],function (){
        //lightgallery
        lightGallery(document.getElementById('lightgallery'));
    });
</script>
</body>
</html>